$10np - 7nq - 8n + 9 = 2p + 4$ Solve for $n$.
Combine constant terms on the right. $10np - 7nq - 8n + {9} = 2p + {4}$ $10np - 7nq - 8n = 2p - {5}$ Notice that all the terms on the left-hand side of the equation have $n$ in them. $10{n}p - 7{n}q - 8{n} = 2p - 5$ Factor out the $n$ ${n} \cdot \left( 10p - 7q - 8 \right) = 2p - 5$ Isolate the $n$ $n \cdot \left( {10p - 7q - 8} \right) = 2p - 5$ $n = \dfrac{ 2p - 5 }{ {10p - 7q - 8} }$ We can simplify this by multiplying the top and bottom by $-1$. $n= \dfrac{-2p + 5}{-10p + 7q + 8}$